package com.bite.messageQueue.mqServer.core;

/**
 * 表示交换机和队列之间的关联关系
 */
public class Binding {
    //交换机ID
    private String exchangeName;
    //队列ID
    private String queueName;
    //配对暗号
    private String bindingKey;

    public Binding() {
    }

    public Binding(String exchangeName, String queueName, String bindingKey) {
        this.exchangeName = exchangeName;
        this.queueName = queueName;
        this.bindingKey = bindingKey;
    }

    /**
     * 获取
     * @return exchangeName
     */
    public String getExchangeName() {
        return exchangeName;
    }

    /**
     * 设置
     * @param exchangeName
     */
    public void setExchangeName(String exchangeName) {
        this.exchangeName = exchangeName;
    }

    /**
     * 获取
     * @return queueName
     */
    public String getQueueName() {
        return queueName;
    }

    /**
     * 设置
     * @param queueName
     */
    public void setQueueName(String queueName) {
        this.queueName = queueName;
    }

    /**
     * 获取
     * @return bindingKey
     */
    public String getBindingKey() {
        return bindingKey;
    }

    /**
     * 设置
     * @param bindingKey
     */
    public void setBindingKey(String bindingKey) {
        this.bindingKey = bindingKey;
    }

    @Override
    public String toString() {
        return "Binding{exchangeName = " + exchangeName + ", queueName = " + queueName + ", bindingKey = " + bindingKey + "}";
    }
}
